<script setup lang="ts">
import { ref } from 'vue';


const showIcon = ref(false);

const switchShow = () => {
  showIcon.value = !showIcon.value;
}

</script>

<template>
  <div>
    <img src="/vite.svg" class="logo" alt="Vite logo" />

    <button @click="switchShow">控制</button>

    <div v-if="showIcon">
      <ImgIcon class="logo vue" icon="vue" folder="logo"></ImgIcon>
      <FontIcon icon="xingbie"></FontIcon>
    </div>

    <FontIcon icon="bianmindianhua"></FontIcon>
    <ImgIcon folder="logo" icon="index"></ImgIcon>

    <img src="./assets/images/logo/vue.svg" class="logo vue" alt="Vue logo" />
  </div>
</template>

<style scoped>
.logo {
  height: 6em;
  padding: 1.5em;
  will-change: filter;
  transition: filter 300ms;
}

.logo:hover {
  filter: drop-shadow(0 0 2em #646cffaa);
}

.logo.vue:hover {
  filter: drop-shadow(0 0 2em #42b883aa);
}
</style>
